﻿@using KDS.Mes.Web.Navigation
@using Abp.Web.Mvc.Extensions
@using KDS.Mes.Authorization
@using Abp.Application.Services.Dto
@using Abp.Extensions
@using KDS.Mes.Web.Models.Common.Modals
@using KDS.Mes.Web.Models.Atlass
@using KDS.Mes.Mes.Atlas
@model AtlassViewModel
@{
    ViewBag.ActiveMenu = PageNames.App.Common.AtlasCpks;
}

@section Styles{

    <link href="~/Content/bootstrap-datetimepicker/css/bootstrap-datetimepicker.min.css" rel="stylesheet" />
}
<style type="text/css">
    table {
        border-collapse: collapse;
        border-spacing: 0;
        border-left: 1px solid #888;
        border-top: 1px solid #888;
        background: #efefef;
    }

    th, td {
        border-right: 1px solid #888;
        border-bottom: 1px solid #888;
        padding: 5px 10px;
    }

    th {
        font-weight: bold;
        background: #ccc;
    }
</style>



@* 注入所需JS *@
@section Scripts
{

    
    <script src="~/Content/bootstrap-datetimepicker/js/bootstrap-datetimepicker.min.js"></script>
    <script src="~/Content/bootstrap-datetimepicker/js/locales/bootstrap-datetimepicker.zh-CN.js"></script>
    <script src="~/Content/BootstrapTable/extensions/export/bootstrap-table-export.js"></script>
<script src="~/Content/layer/layer.js"></script>
@*<script src="~/Content/echarts/echarts.js"></script>*@
<script src="~/Content/echarts/echarts.min.js"></script>
    @*<script src="~/Content/echarts/echarts.min.js"></script>*@
    @*@Html.IncludeScript("~/Views/Atlass/_CreateOrEditAtlasModal.es5.min.js")*@
    @Html.IncludeScript("~/Views/AtlasCpks/Index.js")
}
<div class="box box-info collapsed-box">
    <div class="box-header with-border">
        <h3 class="box-title">@L("Query")</h3>

        <div class="box-tools pull-right">
            <button id="btn-query" type="button" class="btn btn-xs">
                <i class="fa fa-search">@L("Query")</i>
            </button>
            <button id="btn-export" type="button"  class="btn btn-xs">
                <i class="glyphicon glyphicon-export">@L("Export")</i>
            </button>
            <button type="button" class="btn btn-box-tool" data-widget="collapse">
                <i class="fa fa-plus"></i>
            </button>
        </div>
        @*<div class="box-tools pull-right">
            
            <button type="button" class="btn btn-box-tool" data-widget="collapse">
                <i class="fa fa-plus"></i>
            </button>
        </div>*@
    </div>
    <form class="form-horizontal">
        <div class="box-body">
            <div class="form-group">
                <label for="CartypeId" class="col-sm-1 control-label">@L("LineId")</label>
                <div class="col-sm-1">
                    @Html.DropDownList("lineId", Model.Lines.Select(a => a.ToSelectListItem()), new
               {
                   @class = "form-control selectpicker",
                   data_live_search = "true",
                   data_none_selected_text = L("PlaaseSelect"),
                   id = "lineId"
               })
                </div>

                <label for="CartypeId" class="col-sm-1 control-label">@L("StationNoId")</label>
                <div class="col-sm-1">
                    @Html.DropDownList("stationNoId", Model.StationNos.Select(a => a.ToSelectListItem()), new
               {
                   @class = "form-control selectpicker",
                   data_live_search = "true",
                   data_none_selected_text = L("PlaaseSelect"),
                   id = "stationNoId"
               })
                </div>

                <label for="SeatTypeId" class="col-sm-1 control-label">@L("SeatTypeId")</label>
                <div class="col-sm-1">
                    @Html.DropDownList("seatTypeId", Model.SeatTypes.Select(a => a.ToSelectListItem()), new
               {
                   @class = "form-control selectpicker",
                   data_live_search = "true",
                   data_none_selected_text = L("PlaaseSelect"),
                   id = "seatTypeId"
               })
                </div>

                <label class="col-sm-1 control-label">@L("OnlineTime")</label>
                <div class="col-sm-2">
                    <div class="input-group">

                        <input id="time1" type="text" class="form-control" readonly>
                        <span class="input-group-btn">
                            <button class="btn default date-set" type="button">
                                <i class="fa fa-calendar"></i>
                            </button>
                        </span>
                    </div>
                </div>
                <div class="col-sm-2">
                    <div class="input-group">

                        <input id="time2" type="text" class="form-control" readonly>
                        <span class="input-group-btn">
                            <button class="btn default date-set" type="button">
                                <i class="fa fa-calendar"></i>
                            </button>
                        </span>
                    </div>
                </div>
            </div>
            
            <div class="form-group">
                <label for="SeatID" class="col-sm-1 control-label">@L("SeatID")</label>
                <div class="col-sm-2">
                    <input type="text" class="form-control" id="seatID">
                </div>
            </div>
        </div>
    </form>
</div>


<form id="form1" runat="server">
<div id="export1">
    <table id="export" style="width: 100%;">
        <tr>
            <td>
                <!-- 为ECharts准备一个具备大小（宽高）的Dom -->
                <div style="width: 100%; font-size: 12px;">
                    <div id="id">
                        @*<table style="width: 100%;">
                            <tr>
                                <td class="auto-style1">
                                    <h4>扭矩枪报表分析</h4>
                                </td>
                                <td>
                                    输入条码：<asp:TextBox ID="TXT_SEATCH" runat="server"></asp:TextBox>
                                    <asp:Button ID="BTN_SEARCH" runat="server" Text="查询" OnClick="BTN_SEARCH_Click" />
                                    <asp:Button ID="BTN_EXCEL" runat="server" Text="导出" OnClick="BTN_EXCEL_Click" />
                                </td>
                            </tr>
                        </table>*@
                        <table cellpadding="0" cellspacing="0" border="1" style="font-size: 12px; width: 100%; text-align: center">
                            <tr>
                                <td style="background-color: #EEE8AA;" class="auto-style1">生产线</td>
                                <td class="auto-style1">
                                  
                                    <Label ID="line" runat="server" Text=" "></Label>
                                    <br />
                                </td>
                                <td style="background-color: #EEE8AA;" class="auto-style1">工序名称</td>
                                <td>
                                    <Label ID="Labelgongxumingcheng" runat="server" Text=" "></Label>
                                </td>
                                <td style="background-color: #EEE8AA">质量特性</td>
                                <td>扭力</td>
                                <td style="background-color: #EEE8AA">公差上限</td>
                                <td>5.5&nbsp;</td>
                                <td style="background-color: #EEE8AA">组容/频率</td>
                                <td>全数、连续</td>
                                <td style="background-color: #EEE8AA">生产形态 </td>
                                <td>□  批量生产</td>
                            </tr>
                            <tr>
                                <td style="background-color: #EEE8AA;" class="auto-style1">零件名称</td>
                                <td class="auto-style1">
                                    <Label ID="seatType" runat="server" Text=" "></Label>
                                </td>
                                <td style="background-color: #EEE8AA;" class="auto-style1">设备名称</td>
                                <td>
                                    <Label ID="stationNo" runat="server" Text=" "></Label>
                                </td>
                                <td style="background-color: #EEE8AA">规 格 值</td>
                                <td>5</td>
                                <td style="background-color: #EEE8AA">公差下限</td>
                                <td>4.5</td>
                                <td style="background-color: #EEE8AA">图         号</td>
                                <td></td>
                                <td style="background-color: #EEE8AA">日       期</td>
                                <td>
                                    <Label ID="date" runat="server" Text=" "></Label>
                                </td>
                            </tr>
                        </table>
                    </div>
                    <div id="explain" style="width: 24%; float: right;">
                        <div id="explain1">
                            <table cellpadding="0" cellspacing="0" border="1" style="font-size: 12px; width: 100%;">
                                <tr>
                                    <td>说明栏</td>
                                </tr>
                                <tr>
                                    <td>
                                        ●对特殊原因采取说明<br />
                                        *任何超出控制限的点<br />
                                        *连续7点在中心线上或之下<br />
                                        *连续7点上升/下降<br />
                                        *任何其它明显非随机的图形
                                    </td>
                                </tr>
                                <tr>
                                    <td>
                                        ●采取措施的说明<br />
                                        ①不要对过程做不必要改变<br />
                                        ②著名对过程因素(人机料法环或MS)所做的调整
                                    </td>
                                </tr>
                            </table>
                            <table style="text-align: center; width: 100%; font-size: 12px;">
                                <tr>
                                    <td style="width: 25%;">组容</td>
                                    <td style="width: 25%;">A2</td>
                                    <td style="width: 25%;">D3</td>
                                    <td style="width: 25%;">D4</td>
                                    <td style="width: 25%;">d2</td>
                                </tr>
                                <tr>
                                    <td style="width: 25%;">2</td>
                                    <td style="width: 25%;">1.88</td>
                                    <td style="width: 25%;">*</td>
                                    <td style="width: 25%;">3.27</td>
                                    <td style="width: 25%;">1.13</td>
                                </tr>
                                <tr>
                                    <td style="width: 25%;">3</td>
                                    <td style="width: 25%;">1.02</td>
                                    <td style="width: 25%;">*</td>
                                    <td style="width: 25%;">2.57</td>
                                    <td style="width: 25%;">1.69</td>
                                </tr>
                                <tr>
                                    <td style="width: 25%;">4</td>
                                    <td style="width: 25%;">0.73</td>
                                    <td style="width: 25%;">*</td>
                                    <td style="width: 25%;">2.28</td>
                                    <td style="width: 25%;">2.06</td>
                                </tr>
                                <tr>
                                    <td style="width: 25%;">5</td>
                                    <td style="width: 25%;">0.58</td>
                                    <td style="width: 25%;">*</td>
                                    <td style="width: 25%;">2.11</td>
                                    <td style="width: 25%;">2.33</td>
                                </tr>
                                <tr>
                                    <td style="width: 25%;">6</td>
                                    <td style="width: 25%;">0.48</td>
                                    <td style="width: 25%;">*</td>
                                    <td style="width: 25%;">2.00</td>
                                    <td style="width: 25%;">2.53</td>
                                </tr>
                                <tr>
                                    <td style="width: 25%;">7</td>
                                    <td style="width: 25%;">0.42</td>
                                    <td style="width: 25%;">0.08</td>
                                    <td style="width: 25%;">1.92</td>
                                    <td style="width: 25%;">2.70</td>
                                </tr>
                                <tr>
                                    <td style="width: 25%;">8</td>
                                    <td style="width: 25%;">0.37</td>
                                    <td style="width: 25%;">0.14</td>
                                    <td style="width: 25%;">1.86</td>
                                    <td style="width: 25%;">2.85</td>
                                </tr>
                                <tr>
                                    <td style="width: 25%;">9</td>
                                    <td style="width: 25%;">0.34</td>
                                    <td style="width: 25%;">0.18</td>
                                    <td style="width: 25%;">1.82</td>
                                    <td style="width: 25%;">2.97</td>
                                </tr>
                                <tr>
                                    <td style="width: 25%;">10</td>
                                    <td style="width: 25%;">0.31</td>
                                    <td style="width: 25%;">0.22</td>
                                    <td style="width: 25%;">1.78</td>
                                    <td style="width: 25%;">3.08</td>
                                </tr>
                            </table>
                            <table style="width: 100%; font-size: 12px;">
                                <tr>
                                    <td>
                                        1.在确定Cpk前过程必须受控
                                    </td>
                                </tr>
                                <tr>
                                    <td>
                                        2.组容＜7时没有极差下控制限
                                    </td>
                                </tr>
                            </table>
                        </div>
                        <div id="image" runat="server" style="font-size: 12px; width: 100%;">
                            <table cellpadding="0" cellspacing="0" border="1" style="width: 100%;">
                                <tr>
                                    <td>
                                        <img src="~/images/1.png" />
                                    </td>
                                </tr>
                            </table>
                        </div>
                        <div id="explain2" runat="server" style="font-size: 12px;"></div>
                    </div>
                    <div id="chart1up" runat="server" style="width: 75%"></div>
                    <div id="main1" style="width: 75%; height: 280px;"></div>
                    <div id="chart2up" runat="server" style="width: 75%"></div>
                    <div id="main2" style="width: 75%; height: 280px;"></div>
                    <div id="div_Content" runat="server" style="width: 100%;"></div>
                </div>
            </td>
        </tr>
    </table>
</div>

    </form>